home *** CD-ROM | disk | FTP | other *** search
- on MoveOtherShips
- global theFirstBuildingChannel, theLastBuildingChannel, theBackgroundVelocity, theFirstOtherShipChannel, theLastOtherShipChannel, theOtherShipVelocity
- if theBackgroundVelocity <= 0 then
- repeat with h = theFirstOtherShipChannel to theLastOtherShipChannel
- if the right of sprite h < 0 then
- set y1 to random(the stageBottom - the stageTop - the height of sprite theFirstBuildingChannel - the height of sprite h)
- set iWhich to random(7)
- if iWhich = 1 then
- set the memberNum of sprite h to the number of member "Other 1 Left"
- else
- if iWhich = 2 then
- set the memberNum of sprite h to the number of member "Other 2 Left"
- else
- if iWhich = 3 then
- set the memberNum of sprite h to the number of member "Other 3 Left"
- else
- if iWhich = 4 then
- set the memberNum of sprite h to the number of member "Other 4 Left"
- else
- if iWhich = 5 then
- set the memberNum of sprite h to the number of member "Other 5 Left"
- else
- if iWhich = 6 then
- set the memberNum of sprite h to the number of member "Other 6 Left"
- else
- set the memberNum of sprite h to the number of member "Other 7 Left"
- end if
- end if
- end if
- end if
- end if
- end if
- set x1 to the stageRight - the stageLeft
- set x2 to x1 + the width of sprite h
- set y2 to y1 + the height of sprite h
- set the stretch of sprite h to 1
- spriteBox(h, x1, y1, x2, y2)
- set the stretch of sprite h to 0
- next repeat
- end if
- set the locH of sprite h to the locH of sprite h + (theBackgroundVelocity / 2) - theOtherShipVelocity
- end repeat
- else
- repeat with h = theFirstOtherShipChannel to theLastOtherShipChannel
- if the left of sprite h > (the stageRight - the stageLeft) then
- set y1 to random(the stageBottom - the stageTop - the height of sprite theFirstBuildingChannel - the height of sprite h)
- set iWhich to random(7)
- if iWhich = 1 then
- set the memberNum of sprite h to the number of member "Other 1 Left"
- else
- if iWhich = 2 then
- set the memberNum of sprite h to the number of member "Other 2 Left"
- else
- if iWhich = 3 then
- set the memberNum of sprite h to the number of member "Other 3 Left"
- else
- if iWhich = 4 then
- set the memberNum of sprite h to the number of member "Other 4 Left"
- else
- if iWhich = 5 then
- set the memberNum of sprite h to the number of member "Other 5 Left"
- else
- if iWhich = 6 then
- set the memberNum of sprite h to the number of member "Other 6 Left"
- else
- set the memberNum of sprite h to the number of member "Other 7 Left"
- end if
- end if
- end if
- end if
- end if
- end if
- set x1 to the stageRight - the stageLeft
- set x2 to x1 + the width of sprite h
- set y2 to y1 + the height of sprite h
- spriteBox(h, x1, y1, x2, y2)
- set x1 to 0 - the width of sprite h
- set x2 to x1 + the width of sprite h
- set y2 to y1 + the height of sprite h
- set the stretch of sprite h to 1
- spriteBox(h, x1, y1, x2, y2)
- set the stretch of sprite h to 0
- next repeat
- end if
- set the locH of sprite h to the locH of sprite h + (theBackgroundVelocity / 2) - theOtherShipVelocity
- end repeat
- end if
- end
-